// 获取组织架构信息
import request from '@/utils/request'
export function getDepartments() {
  return request({
    url: '/company/department'
  })
}
// 删除组织架构的部门
export function delDepartments(id) {
  return request({
    url: `/company/department/${id}`,
    method: 'DELETE'
  })
}
// 添加组织架构人员
export function addDepartments(data) {
  return request({
    url: '/company/department',
    method: 'POST',
    data
  })
}
// 获取组织架构人员
export function getDepartDetail(id) {
  return request({
    url: `/company/department/${id}`
  })
}
// 根据id修改部门
export function updateDepartDetail(data) {
  return request({
    url: `/company/department/${data.id}`,
    method: 'PUT',
    data
  })
}
